package practise1;

public class Test {
    public static void main(String[] args) {
        Cat cat = new Cat("加菲猫",4);
        Duck duck= new Duck("唐小鸭",2);
        System.out.println("动物名字"+"\t"+"腿的条数"+"\t"+"动物叫");
        System.out.print(cat.getName()+"\t"+cat.getLegnum()+"\t\t");
        cat.shout();
        System.out.print(duck.getName()+"\t"+duck.getLegnum()+"\t\t");
        duck.shout();
    }
}
